﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

namespace WebsiteAdmin.Wilson.AdInfo
{
    public partial class AdList : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                GetCatAdList(Global.ConnWilson, 1);
            }
        }

        protected void GetCatAdList(string strCon, int type)
        {
            using (DataTable dtAdList = Bll.CategoryAd.MULTIPLE(strCon, type))
            {
                if (dtAdList != null && dtAdList.Rows.Count > 0)
                {
                    this.repCatAdList.DataSource = dtAdList.DefaultView;
                    this.repCatAdList.DataBind();
                }
            }
        }
    }
}
